class CreateOrderPayments < ActiveRecord::Migration
  def change
    create_table :order_payments, :force => true do |t|
      t.references :order, :null => false
      t.references :billing_method, :null => false
      t.references :order_billing_address
      t.decimal    :cost, :precision => 6, :scale => 2
    end

    add_index :order_payments, :order_id
    add_index :order_payments, :order_billing_address_id
    add_index :order_payments, :billing_method_id
  end
end